#pragma once

#include <SDL2/SDL.h>

class slInput
{
public:
	slInput();
	~slInput();
	void updateInput();
	bool isFinished() const;
	bool getKey(const SDL_Scancode key) const;
	bool getMouseButton(const Uint8 button) const;
	bool mouseMoved() const;
	int getX() const;
	int getY() const;
	int getXRel() const;
	int getYRel() const;
	void showCursor(bool state) const;
	void catchCursor(bool state) const;

private:
	SDL_Event 	_event;
	bool 		_keys[SDL_NUM_SCANCODES];
	bool 		_mouseButtons[8];

	int			_x;
	int			_y;
	int 		_xRel;
	int 		_yRel;
	bool 		_finished;
};